From: Keir Fraser Date: Wed, 7 May 2008 08:17:52 +0000 (+0100) Subject: msix: Further fixes to Python arithmetic. X-Git-Tag: archive/raspbian/4.8.0-1+rpi1~1^2~14215^2~59 X-Git-Url: https://dgit.raspbian.org/%22http:/www.example.com/cgi/%22https://%22%22/%22http:/www.example.com/cgi/%22https:/%22%22?a=commitdiff_plain;h=d4a75659655f95274f4690483931b1d6f008146e;p=xen.git msix: Further fixes to Python arithmetic. Signed-off-by: Keir Fraser --- diff --git a/tools/python/xen/util/pci.py b/tools/python/xen/util/pci.py index d70a998b25..0598f904bd 100644 --- a/tools/python/xen/util/pci.py +++ b/tools/python/xen/util/pci.py @@ -30,7 +30,7 @@ PCI_STATUS_CAP_MASK = 0x10 PCI_STATUS_OFFSET = 0x6 PCI_CAP_OFFSET = 0x34 MSIX_BIR_MASK = 0x7 -MSIX_SIZE_MASK = 0x3ff +MSIX_SIZE_MASK = 0x7ff #Calculate PAGE_SHIFT: number of bits to shift an address to get the page number PAGE_SIZE = resource.getpagesize() @@ -122,7 +122,7 @@ class PciDevice: message_cont_hi = ord(conf_file.read(1)) self.msix=1 self.msix_entries = (message_cont_lo + \ - message_cont_hi << 8) \ + (message_cont_hi << 8)) \ & MSIX_SIZE_MASK t_off=conf_file.read(4) p_off=conf_file.read(4)